import { createApp } from 'vue'
import router from './router'
import { createI18n } from 'vue-i18n';
import messages from './locales';
import ElementPlus from 'element-plus'
import zhCn from 'element-plus/es/locale/lang/zh-cn'
import App from './App.vue'
import './assets/styles/style.scss'
import './assets/iconfont/iconfont.css'
// 创建实例对象
const i18n = createI18n({
    legacy: false,  // 设置为 false，启用 composition API 模式
    messages,
    locale: 'zh'
})
const app = createApp(App)
app.use(router)
app.use(ElementPlus, {
    locale: zhCn,
})
app.use(i18n)
app.mount('#app')
